<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<div th:replace="pages/admin/commons/header :: header"></div>
<body style="background-color:#fff">
<div class="wap-container">
    <div class="panel">
        <div class="panel-body">
            <form action="/childhealth/childrenHyjcmb/data-upd" method="post" class="form form-horizontal"
                  id="form-member-add">
                <div class="row clearfix">
                    <br><br><br>
                    <input type="hidden" th:value="${type} == toUpd ? 'upd' : 'add'" name="type">

                    <input type="hidden" th:if="${result} != null" th:value="${result.id}" name="id">
                    <input type="hidden" th:if="${result} == null" name="id">


                    <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>代码：</label>
                    <div class="form-controls col-xs-8 col-sm-9">

                        <input style="width: 100%" required lay-verify="required" type="number" class="input-text"
                               th:if="${result} != null"
                               th:value="${result.code}"
                               name="code">
                        <input style="width: 100%" required lay-verify="required" type="number" class="input-text"
                               th:if="${result} == null" placeholder="0000"
                               name="code">

                    </div>

                    <br><br><br>
                    <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>名称：</label>
                    <div class="form-controls col-xs-8 col-sm-9">

                        <input style="width: 100%" required lay-verify="required" type="text" class="input-text in1"
                               th:if="${result} != null"
                               th:value="${result.name}"
                               placeholder="名称"
                               name="name">
                        <input style="width: 100%" required lay-verify="required" type="text" class="input-text in1"
                               th:if="${result} == null"
                               placeholder="名称"
                               name="name">

                    </div>
                    <br><br><br>
                    <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>类别：</label>
                    <div class="form-controls col-xs-8 col-sm-9">

                        <input style="width: 100%" required lay-verify="required" type="text" class="input-text in2"
                               th:if="${result} != null"
                               th:value="${result.category}"
                               placeholder="类别"
                               name="category">
                        <input style="width: 100%" required lay-verify="required" type="text" class="input-text in2"
                               th:if="${result} == null"
                               placeholder="类别"
                               name="category">

                    </div>
                    <br><br><br>

                    <label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>公用：</label>
                    <div class="form-controls col-xs-8 col-sm-9">

                        <input th:if="${result} != null" type="checkbox" name="isPublic"
                               th:checked="${result.isPublic} == 1">
                        <input th:if="${result} == null" type="checkbox" name="isPublic">

                    </div>
                    <br><br><br>
                </div>
                <div class="row clearfix">
                    <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                        <button style=" margin-left: inherit" class="btn btn-primary radius" type="submit">
                            [[${type}=='toUpd'? '修改':'添加']]
                        </button>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
<div th:replace="pages/admin/commons/footer :: footer"></div>
<script th:src="@{/layui/layui.js}" charset="utf-8"></script>
<script type="text/javascript">


</script>
</body>
</html>
